chore: Improve usage of MessageListProvider#35577
Conversation
|
Looks like this PR is ready to merge! 🎉 |
|
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## develop #35577 +/- ##
===========================================
+ Coverage 61.19% 61.21% +0.02%
===========================================
Files 3157 3007 -150
Lines 74670 71491 -3179
Branches 16677 16343 -334
===========================================
- Hits 45694 43764 -1930
+ Misses 25877 24757 -1120
+ Partials 3099 2970 -129
Flags with carried forward coverage won't be shown. Click here to find out more. 🚀 New features to boost your workflow:
|
|
Code Review Completed! 🔥The code review was successfully completed based on your current configurations. Kody Guide: Usage and ConfigurationInteracting with Kody
Current Kody ConfigurationReview OptionsThe following review options are enabled or disabled:
|
apps/meteor/client/components/message/toolbar/items/actions/QuoteMessageAction.tsx
Show resolved
Hide resolved
apps/meteor/client/components/message/variants/room/RoomMessageContent.tsx
Show resolved
Hide resolved
apps/meteor/client/components/message/variants/room/RoomMessageContent.tsx
Show resolved
Hide resolved
apps/meteor/client/components/message/variants/thread/ThreadMessageContent.tsx
Show resolved
Hide resolved
Code Review Completed! 🔥The code review was successfully completed based on your current configurations. Kody Guide: Usage and ConfigurationInteracting with Kody
Current Kody ConfigurationReview OptionsThe following review options are enabled or disabled:
|
Code Review Completed! 🔥The code review was successfully completed based on your current configurations. Kody Guide: Usage and ConfigurationInteracting with Kody
Current Kody ConfigurationReview OptionsThe following review options are enabled or disabled:
|
Code Review Completed! 🔥The code review was successfully completed based on your current configurations. Kody Guide: Usage and ConfigurationInteracting with Kody
Current Kody ConfigurationReview OptionsThe following review options are enabled or disabled:
|
Code Review Completed! 🔥The code review was successfully completed based on your current configurations. Kody Guide: Usage and ConfigurationInteracting with Kody
Current Kody ConfigurationReview OptionsThe following review options are enabled or disabled:
|
Code Review Completed! 🔥The code review was successfully completed based on your current configurations. Kody Guide: Usage and ConfigurationInteracting with Kody
Current Kody ConfigurationReview OptionsThe following review options are enabled or disabled:
|
Code Review Completed! 🔥The code review was successfully completed based on your current configurations. Kody Guide: Usage and ConfigurationInteracting with Kody
Current Kody ConfigurationReview OptionsThe following review options are enabled or disabled:
|
Code Review Completed! 🔥The code review was successfully completed based on your current configurations. Kody Guide: Usage and ConfigurationInteracting with Kody
Current Kody ConfigurationReview OptionsThe following review options are enabled or disabled:
|
Code Review Completed! 🔥The code review was successfully completed based on your current configurations. Kody Guide: Usage and ConfigurationInteracting with Kody
Current Kody ConfigurationReview OptionsThe following review options are enabled or disabled:
|
Code Review Completed! 🔥The code review was successfully completed based on your current configurations. Kody Guide: Usage and ConfigurationInteracting with Kody
Current Kody ConfigurationReview OptionsThe following review options are enabled or disabled:
|
Proposed changes (including videos or screenshots)
Move some message dependencies up to the provider to decrease usage of
useSettingin the message list, as each hook call creates a new meteor computation.Issue(s)
CORE-1045
Steps to test or reproduce
Further comments
This pull request focuses on improving the usage of the
MessageListProviderwithin the Rocket.Chat codebase. The changes include:GazzodownTextcomponent to useuseMessageListShowRealNameinstead ofuseSettingfor determining the 'useRealName' preference, and adding hooks from@rocket.chat/ui-contexts.MessageHeadercomponent to utilize hooks from theMessageListContextfor format functions.useNormalizedMessagehook by consolidating imports fromMessageListContext.useOembedLayouthook to useuseMessageListOembedEnabledfor checking oembed settings.QuoteMessageActioncomponent to useuseMessageListAutoTranslatefor auto-translate options.useReadReceiptsDetailsActionand other components to use context hooks, enhancing modularity and maintainability.useSettinghooks with context-specific hooks across multiple components to improve code organization and consistency.useMessageBodyhook by reducing dependencies and parameters, directly usinguseMessageListAutoTranslate.MessageListProviderby introducing new imports for date and time formatting, restructuring auto-translate and read receipt settings, and refining the context value.